import 'package:flutter2/model/user_entity.dart';
import 'package:flutter2/utils/sp.dart';
import 'package:get/get.dart';

class UserUtil {
  UserUtil._();

  static UserEntity getUser() {
    return UserEntity.fromJson(SPUtil.getObject("user"));
  }

  static bool isLogin() {
    return getUser().token.isBlank == false;
  }
}
